#include <Rectangle.h>
Rectangle::Rectangle(const u32  width, const u32 height):width(width),height(height)
{
}
u32 Rectangle::getWidth() const
{
	return width;
}
u32 Rectangle::getHeight() const
{
	return height;
}
u32 Rectangle::getArea() const
{
	return width*height;
}
u32 Rectangle::getPerimeter() const
{
    	return 2 * (width + height);
}
void Rectangle::setWidth(const u32  width)
{
	this->width = width;
}
void Rectangle::setHeight(const u32 height)
{
	this->height = height;
}
Rectangle::~Rectangle()
{
}

Square::Square(const u32 side): Rectangle(side, side)
{
}
Square::~Square()
{
}
u32 Square::getSide() const
{
        return getWidth();
}
void Square::setSide(const u32 side)
{
	setWidth(side);
	setHeight(side);
}
